package com.example.script.admin.enums;

import com.example.script.common.api.IErrorCode;

public enum AdminResult implements IErrorCode {
    REGISTER_SUCCESS(0,"注册成功"),
    REGISTER_FAILED(1,"注册失败"),
    REGISTER_FAILED_USERNAME_SAME(2,"注册失败,用户名重复"),
    PHONE_ERROR(3,"登陆失败,用户名错误,请重试"),
    PHONE_ALREADY_REGISTERED(4,"登陆失败,密码错误,请重试"),
    NETWORK_ERROR(5,"网络错误");

    private final long code;
    private final String message;

    AdminResult(long code, String message) {
        this.code = code;
        this.message = message;
    }

    @Override
    public long getCode() {
        return code;
    }

    @Override
    public String getMessage() {
        return message;
    }
}
